package cn.com.blueInfo.bpm.person.entity;

import cn.com.blueInfo.bpm.common.entity.BaseEntity;
import cn.com.blueInfo.bpm.person.enums.UserIdentityPrimaryOrgFlag;
import cn.com.blueInfo.bpm.person.enums.UserIdentityPrimaryStatus;
import cn.com.blueInfo.bpm.person.enums.UserIdentityStatus;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.time.LocalDate;

/**
 * 员工身份信息表
 * @author suxch
 * @since 2025-08-24 01:39:52
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName(value = "mc_osm_user_identity", autoResultMap = true)
@Schema(description = "员工身份信息表")
public class UserIdentity extends BaseEntity {

    /** ID */
    @TableId(type = IdType.INPUT)
    @Schema(description = "ID")
    private Long id;
    /** 用户基本信息ID */
    @Schema(description = "用户基本信息ID")
    private Long userBaseId;
    /** 用户账户信息ID */
    @Schema(description = "用户账户信息ID")
    private Long userAccountId;
    /** 所属部门ID */
    @Schema(description = "所属部门ID")
    private Long orgId;
    /** 职务ID */
    @Schema(description = "职务ID")
    private Long headShipId;
    /** 岗位ID */
    @Schema(description = "岗位ID")
    private Long postId;
    /** 职务状态：1-主职，2-兼职 */
    @Schema(description = "职务状态：1-主职，2-兼职")
    private UserIdentityPrimaryStatus primaryStatus;
    /** 任职开始日期 */
    @Schema(description = "任职开始日期")
    private LocalDate startDate;
    /** 任职结束日期 */
    @Schema(description = "任职结束日期")
    private LocalDate endDate;
    /** 身份状态：1-有效，0-无效 */
    @Schema(description = "身份状态：1-有效，0-无效")
    private UserIdentityStatus identityStatus;
    /** 主组织标识：1-主要，0-次要 */
    @Schema(description = "主组织标识：1-主要，0-次要")
    private UserIdentityPrimaryOrgFlag primaryOrgFlag;

}
